package cn.hs.mapper;

import cn.hs.entity.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface UserMapper {

    //查询所有并分页与模糊查询
    public List<User> selectAll(User user);
    //增加
    public int insert(User user);
    //修改
    public int update(User user);
    //删除
    public int delete(Integer id);
    //根据id查询
    public User selectById(Integer id);
    //根据用户名查询
    public User selectName(String username);
    public User selectNameAndPwd(@Param("username") String username, @Param("password") String password);
}
